from django.urls import path, include, re_path
from blog.views import *


app_name = 'blog'
urlpatterns = [
    path('', IndexViews.as_view(), name='index'),
    path('registe/', Registe.as_view(), name='registe'),
    path('login/', Login.as_view(), name='login'),
    path('myindex/<int:userid>/', MyIndexView.as_view(), name='myindex'),
    path('logout/', LogoutView.as_view(), name='logout'),
    path('authorindex/<int:userid>/', AuthorIndexView.as_view(), name='authorindex'),
    path('tag/(?P<pk>[0-9]+)/', TagView.as_view(), name='tag'),
    path('archives/<int:year>/<int:month>/', archives, name='archives'),
    re_path('blog/(?P<pk>[0-9]+)/', BlogDetailView.as_view(), name='detail'),
    re_path('category/(?P<pk>[0-9]+)/', CategoryView.as_view(), name='category')
]